package cc.vv.btpartyjob.binder

import cc.vv.mvp.binder.BaseDataBinder
import cc.vv.btpartyjob.bean.AppMainTabHostDataObj
import cc.vv.btpartyjob.delegate.BaseTableHostDelegate

/**
 * 公共TabHost数据视图绑定类
 * Created by sun.li on 2018/9/5.
 * @author sun.li
 */
class AppMainTableHostDataBinder : BaseDataBinder<BaseTableHostDelegate, AppMainTabHostDataObj> {

    override fun viewBindModel(viewDelegate: BaseTableHostDelegate?, data: AppMainTabHostDataObj?) {
        if (data?.mainTabIconArray != null && data.fragmentArray != null && data.mainTabTextArray != null) {
            viewDelegate?.initTab(data.mainTabIconArray, data.fragmentArray, data.mainTabTextArray)
//            viewDelegate?.initSectorMenuButton(data.mainBottomSectorMenu)
        }
    }

    override fun getDataClass(): Class<AppMainTabHostDataObj> {
        return AppMainTabHostDataObj::class.java
    }


}